package com.stud.system.service;

import com.stud.common.enums.FileBusinessType;
import com.stud.common.mybatis.BaseService;
import com.stud.system.domain.FileLink;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;
import java.util.Map;

/**
 * 系统文件关联Service接口
 *
 * @author Stud
 * @date 2022-10-08
 */
public interface FileLinkService extends BaseService<FileLink> {

    FileLink link(MultipartFile file, FileBusinessType businessType, Long businessId);

    List<FileLink> link(MultipartFile[] files, FileBusinessType businessType, Long businessId);

    String upload(MultipartFile file, FileBusinessType businessType, Long businessId);

    Map<Long, List<FileLink>> fileLinkMap(FileBusinessType businessType, List<Long> businessIds);

    Map<Long, List<Long>> fileLinkIdMap(FileBusinessType businessType, List<Long> businessIds);

}
